home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Loadstar 9
/
009.d81
/
column program
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-08-26
|
743b
|
25 lines
10 poke53280,5:poke53281,0:poke646,1
100 data123,3.33333,6.66666,-45.25555,9999,.01234,-5678,0
110 readv
120 v1=4:v2=0:gosub50000:printv$;" ";
130 v1=3:v2=1:gosub50000:printv$;" ";
140 v1=3:v2=3:gosub50000:printv$
150 ifv<>0goto110
160 goto60000
50000 rem 'using' arrange in columns
50010 rem v is value; v1,v2 positions
50020 v4=int(v*10^v2+.5)
50030 v$=right$(" "+str$(v4),v1+v2+1)
50040 ifv2<1goto50080
50050 forv5=v1+2tov1+v2-1:ifasc(mid$(v$,v5))<48thennextv5
50060 v6=v5-v1-1
50070 v$=mid$(v$,v6,v1+1)+left$(".00000",v6)+mid$(v$,v5)
50080 ifasc(v$)>47thenv$=left$("************",v1+v2+2+(v2=0))
50090 return
60000 print:print"want to see it again <y/n>?"
60010 poke198,0:wait198,1:getk$:ifk$<>"y"andk$<>"n"thenpoke53280,rnd(1)*15:goto60010
60020 ifk$="y"thenrestore:print"[147]":goto100
63000 rem connect back to l.s.
63002 print"[147]load"chr$(34)"c.payload"chr$(34)",8":print"run"
63004 poke198,0:poke631,13:poke632,13:poke198,2:end